﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using System.Runtime.Serialization;
namespace K.EnterpriseLibary
{
    [DataContract]
    [Serializable]
    public class IdObject : BaseInfo, INewID
    {
        protected override string KeyMemeber
        {
            get
            {
                return "ID";
            }
        }

        [DataMember]
        public Guid ID { get; set; }

        public IdObject()
        {
            ID = Guid.NewGuid();
        }

        #region INewID 成员

        public virtual void NewID()
        {
            ID = Guid.NewGuid();
        }

        #endregion
    }
}
